AppendPAR
Use this procedure/function to append paragraph text to the end of a multiline text field from a paragraph resource (PAR) file. This procedure only works on multiline text fields.
Syntax:
AppendPAR (PAR, InsertFld, Field, Section, Form, Group)
The system optionally returns a one (1) if successful and zero (0) if unsuccessful.
This procedure opens the paragraph resource you defined in the PAR parameter and copies the text. It then appends that text in the field you specified in the Field parameter. If necessary, the text will be reformatted appropriately for the destination field.
Use the Refresh procedure to make sure all appended text appears in the field.
Here are some examples:
Procedure |
Result |
Explanation |
#rc = AppendPar ("Message", , "Name_Line"); Refresh ( ); |
1 or 0 |
The text from the named Message.PAR is appended to the multiline text field, called Name_Line . The system then refreshes the display. |
#rc = AppendPar (".\mstrres\messages\msg1", , "Name_Line", "Mailer"); Refresh ( ); |
1 or 0 |
The path specifies a specific MSG1.PAR to append to the multiline text field, called Name_Line , which is on the section named Mailer. The system then refreshes the display. |
#rc = AppendPar("message", "Address1" , "Name_Line"); Refresh ( ); |
1 or 0 |
The fields from the appended paragraph text are inserted before the variable field named Address1 in the tabbing sequence. The system then refreshes the display. |
Note: If you specifically name a section resource by appending the file extension .FAP to the name, the system will assume that you really meant to do the equivalent of AppendTXM and will include the content from a section file.
See also